home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Ahoy 1985 September
/
Ahoy_Magazine_85-09_1985_Double_L.d64
/
s&e file addr
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-10-26
|
1KB
|
44 lines
1 poke53280,0:poke53281,3:poke646,0
2 print"[147] start & end file address":rem by dave smart
4 fori=828to904:reada:pokei,a:next
6 open15,8,15,"i0"
8 input" file to check ";f$:print
10 q=24:p=q*256:s=int(p/256)
12 poke251,p-s*256:poke252,s
14 print" ";f$
16 open1,8,2,"0:"+f$
18 get#1,a$,b$
20 d=asc(a$+chr$(0))+256*asc(b$+chr$(0))
22 input#15,e,e$,e1,e2
24 ife>0thenprint:print,e$:close1:close15:end
30 printtab(15)"start addr.(dec)"d
32 w=d: gosub54
34 printtab(26)"(hex) "h$
36 print"please wait..."
38 sys831
40 f=p:p=peek(251)+peek(252)*256:t=p
42 z$=right$(" "+str$(t-f),5)
44 print"[145] "z$;" bytes of mem."
46 z=val(z$)
48 printtab(17)"end addr.(dec)"z+w:d=w+z:gosub54
50 printtab(26)"(hex) "h$
52 goto60
54 h$="":m=4096:n=3:ifd<256thenm=16:n=1
56 forh=0ton:c=int(d/m):d=d-c*m:m=m/16:c=c+48:ifc>57thenc=c+7
58 h$=h$+chr$(c):next:return
60 close1:close15
62 print"do you wish to check another file (y/n)"
64 geta$:ifa$=""then64
66 ifa$<>"y"thenend
68 ifa$="y"then6
70 data 76,96,3,162,1,32,198,255,32
72 data 228,255,160,0,145,251,230
74 data 251,208,8,230,252,165,252
76 data 201,208,240,6,165,144,41,64
78 data 240,231,76,204,255,162,1,32
80 data 201,255,162,54,134,1,160,0
82 data 177,251,32,210,255,230,251
84 data 208,2,230,252,165,251,197,253
86 data 208,239,165,252,197,254,208
88 data 233,162,55,134,1,76,204,255